package main

import "fmt"

type C interface {
	Fly()
}

type A struct {
	Name string
}

func (a *A) Climb() {
	fmt.Println("猴子生来会爬树")
}

type B struct {
	A
}

func (b *B) Fly() {
	fmt.Println("会飞了")
}

func Test(c C) {
	fmt.Println("ok")
}

func main() {
	b := B{A{"悟空"}}
	b.Fly()

	Test(&b)
}
